package com.manager.gen.module.entity.enterprise;

import com.manager.commons.base.BaseEntity;
import com.manager.commons.utils.StringUtil;

/**
 * GenEnterprise
 *
 * @author manager
 * @version 1.0
 */
public class GenEnterprise extends BaseEntity {

    private String name;//企业名称
    private String contacts;//联系人
    private String phone;//电话
    private String provinceCode;//省份编码
    private String provinceName;//省份名称
    private String cityCode;//市编码
    private String cityName;//市名称
    private String areaCode;//区编码
    private String areaName;//区名称
    private String address;//详细地址
    private String logo;//企业logo
    private String userNumber;//用户数量
    private String addressName;

    private String userNumberName;

    public void setName(String name) {
        this.name = name;
    }

    public String getName() {
        return this.name;
    }

    public String getContacts() {
        return contacts;
    }

    public void setContacts(String contacts) {
        this.contacts = contacts;
    }

    public void setPhone(String phone) {
        this.phone = phone;
    }

    public String getPhone() {
        return this.phone;
    }

    public void setProvinceCode(String provinceCode) {
        this.provinceCode = provinceCode;
    }

    public String getProvinceCode() {
        return this.provinceCode;
    }

    public void setProvinceName(String provinceName) {
        this.provinceName = provinceName;
    }

    public String getProvinceName() {
        return this.provinceName;
    }

    public void setCityCode(String cityCode) {
        this.cityCode = cityCode;
    }

    public String getCityCode() {
        return this.cityCode;
    }

    public void setCityName(String cityName) {
        this.cityName = cityName;
    }

    public String getCityName() {
        return this.cityName;
    }

    public void setAreaCode(String areaCode) {
        this.areaCode = areaCode;
    }

    public String getAreaCode() {
        return this.areaCode;
    }

    public void setAreaName(String areaName) {
        this.areaName = areaName;
    }

    public String getAreaName() {
        return this.areaName;
    }

    public void setAddress(String address) {
        this.address = address;
    }

    public String getAddress() {
        return this.address;
    }

    public void setLogo(String logo) {
        this.logo = logo;
    }

    public String getLogo() {
        return this.logo;
    }

    public void setUserNumber(String userNumber) {
        this.userNumber = userNumber;
    }

    public String getUserNumber() {
        return this.userNumber;
    }

    public String getAddressName() {
        StringBuffer sb = new StringBuffer();
        if (StringUtil.isNotEmpty(provinceName)) sb.append(provinceName);
        if (StringUtil.isNotEmpty(cityName)) sb.append(cityName);
        if (StringUtil.isNotEmpty(areaName)) sb.append(areaName);
        if (StringUtil.isNotEmpty(address)) sb.append(address);
        return sb.toString();
    }

    public String getUserNumberName() {
        return userNumber.equals("0") ? "不限制" : userNumber;
    }
}
